package org.blogsomy.controller;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

import com.google.code.lightsomy.annotations.Action;
import com.google.code.lightsomy.annotations.Controller;
import com.google.code.lightsomy.output.Renderer;

@Controller
public class ErrorController {
	
	@SuppressWarnings("unused")
	private static Log log = LogFactory.getLog(ErrorController.class);
	
	@Action(route = "^/error/404$")
	public void error404(HttpServletRequest req, HttpServletResponse res) {
		Renderer r = Renderer.getRenderer(Renderer.Type.VELOCITY, req, res);
		r.output(r.render("/view/error/error404.tpl"));
	}
}
